package com.my.api.request;

import java.io.Serializable;

import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.serializer.SerializerFeature;
/**
 * 应用请求头
 * @author ch
 *
 */
public class AppRequestHead implements Serializable{

	
		/**
		 * 
		 */
		private static final long serialVersionUID = -4641042452894112133L;
	
		//APP  user,jl,pm
		private String app;
		
		//来源 wechat,pc...
		private String source;
		
		//api版本号
		private String v;
		
		//时间戳		格式: 2017-6-29 20:24:00
		private String timestamp;
		
		//数字签名
		private String sign;
		
		//App token  某些方法需要，非必须
		private String token;
		
		
		
		
		public AppRequestHead() {
			super();
		}

		

		public AppRequestHead(String timestamp, String token) {
			super();
			this.timestamp = timestamp;
			this.token = token;
		}



		public AppRequestHead(String app, String source, String timestamp, String token) {
			super();
			this.app = app;
			this.source = source;
			this.timestamp = timestamp;
			this.token = token;
		}



		public String getApp() {
			return app;
		}



		public void setApp(String app) {
			this.app = app;
		}



		public String getSource() {
			return source;
		}



		public void setSource(String source) {
			this.source = source;
		}



		public String getV() {
			return v;
		}



		public void setV(String v) {
			this.v = v;
		}



		public String getTimestamp() {
			return timestamp;
		}



		public void setTimestamp(String timestamp) {
			this.timestamp = timestamp;
		}



		public String getSign() {
			return sign;
		}



		public void setSign(String sign) {
			this.sign = sign;
		}



		public String getToken() {
			return token;
		}



		public void setToken(String token) {
			this.token = token;
		}



		@Override
		public String toString() {
			return JSON.toJSONString(this, SerializerFeature.UseISO8601DateFormat);
		}	
}
